'use strict';

module.exports = app => {
  const mongoose = app.mongoose;
  const Schema = mongoose.Schema;
  const ObjectId = Schema.ObjectId;

  const OtherSchema = new Schema({
    name: { type: String, index: true },
    content: { type: String },
    title: { type: String },
    state: { type: Number, default: 1 }, 
    scope: { type: Number, default: 1}, 
    type: { type: Number, default: 1 }, 
    des:{ type: String },
    obj:{ type: Object },
    array:{ type: Array },
    createtime: { type: Date, default: Date.now, index: true },
    shoptoplvid: { type: String },   //三级商户id
    deleted: { type: Boolean, default: false },//状态是否被删除
  });

  

  return mongoose.model('other', OtherSchema);
};
